package com.lark.web.service;

import com.github.dockerjava.api.command.InspectImageResponse;
import com.lark.common.core.service.BaseService;
import com.lark.web.domain.Image;
import org.springframework.core.io.InputStreamResource;
import org.springframework.core.io.Resource;
import org.springframework.http.ResponseEntity;
import org.springframework.web.servlet.mvc.method.annotation.StreamingResponseBody;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 * 镜像Service接口
 * @author fei
 * @email 952597665@qq.com
 * @date 2024-08-11
 */
public interface ImageService extends BaseService<Image> {

    /**
     * 批量删除镜像
     * @param ids 需要删除的镜像ID集合
     * @return 结果
     */
    public int deleteImageByIds(String[] ids);

    public boolean startImage(Image image);

    public InspectImageResponse viewImage(Image image);

    public ResponseEntity<StreamingResponseBody> exportImage(Image image, HttpServletResponse response) throws IOException;

}
